package iedcyt.acute.view.widgets;

import iedcyt.acute.dataAccess.domain.maesorg.Datos_Level;
import org.eclipse.swt.SWT;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.TableColumn;
import org.eclipse.swt.widgets.TableItem;

/**
 * Tabla para Datos Level
 * @author 53385255R
 *
 */
public class DatosLevelTable extends NormalizationTable<Datos_Level> {
	
	public DatosLevelTable(Composite composite, int style)
	{
		super(composite, style);
		LABEL = "Datos Level";
		_label.setText(LABEL);
		
		_table.setHeaderVisible(true);
		String[] titles = { "JNL Abbrev",  "ISSN", "JNL Full", "ABV_Corregido" };
	
		for (int loopIndex = 0; loopIndex < titles.length; loopIndex++) {
			TableColumn column = new TableColumn(_table, SWT.NULL);
			column.setText(titles[loopIndex]);
		}
		addSort();
	}
	
	
	
	private void addSort()
	{
		
		
	}
	
	@Override
	protected void setItemElement(Datos_Level element, TableItem item) {
				
		item.setText(0, element.get_Jnl_Abbrev());
		item.setText(1, element.get_ISSN() == null? "":element.get_ISSN());
		item.setText(2,	element.get_Full_Jnl_Name() == null? "":element.get_Full_Jnl_Name());
		item.setText(3, element.get_ABV_Corregida() == null? "":element.get_ABV_Corregida());
		
	}



	
}
